import request from "./axios.config";

// 获取门店
export const getStore = params => {
  return request({
    url: "/salesroom/room_show",
    method: "get",
    params
  });
};

// 新门店上传
export const uploadStore = params => {
  return request({
    url: "/salesroom/room_add",
    method: "post",
    data: params
  });
};

// banner上传
export const uploadBanner = params => {
  return request({
    url: "/banner/img_add",
    method: "post",
    data: params
  });
};

// banner获取
export const getBanner = params => {
  return request({
    url: "/banner/img_show",
    method: "get",
    params
  });
};

// 修改公司背景
export const postCompany = params => {
  return request({
    url: "/journalism/background_add",
    method: "post",
    data: params
  });
};

// 获取公司背景
export const getCompany = params => {
  return request({
    url: "/journalism/background_set",
    method: "get",
    data: params
  });
};

// 删除指定ID数据
export const deleteData = params => {
  return request({
    url: "/journalism/whole_delete",
    method: "get",
    params
  });
};

// 获取新闻列表
export const journalismSee = params => {
  return request({
    url: "/journalism/journalism_see",
    method: "get",
    params
  });
};

// 新闻保存
export const journalismAdd = params => {
  return request({
    url: "/journalism/journalism_add",
    method: "post",
    data: params
  });
};

// 获取产品列表
export const product = params => {
  return request({
    url: "/journalism/product",
    method: "get",
    params
  });
};

// 添加产品
export const productAdd = params => {
  return request({
    url: "/journalism/product_add",
    method: "post",
    data: params
  });
};

// 联系我们后台展示接口
export const contactInfoShow = params => {
  return request({
    url: "/journalism/point_set",
    method: "get",
    params
  });
};
